package com.xy.async.controller;

import com.xy.async.service.HelloService;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
public class HelloController {
    @Resource
    public HelloService service;

    @RequestMapping("/hello")
    public String hello() {
        service.helloService();
        return "Hello World1";
    }
    @RequestMapping("/add")
    public String add() {
        service.add();
        return "add";
    }

}